package com.spring.service.Impl;

import com.spring.dao.Impl.UserDaoImpl;
import com.spring.dao.UserDao;
import com.spring.service.UserService;
import com.spring.utils.BeanFactory;

public class UserServiceImpl implements UserService {

    public void print() throws ClassNotFoundException, IllegalAccessException, InstantiationException {
      // UserDao userDao = (UserDao) Class.forName("com.spring.dao.Impl.UserDaoImpl").newInstance();
        //userDao.print();
      /*  UserDao userDao = new UserDaoImpl();
        userDao.print();*/
        UserDao userDao = (UserDao) BeanFactory.getBean("userDao");
        userDao.print();
    }
}
